<?
if ($poll == 1) {
	echo "<div id=\"poll1\">\n";
	echo "<img src=\"http://www.sonixshop.com/images/poll_header.gif\" title=\"soniXsurvey\" width=\"156\" height=\"22\"><br>\n";
	echo "<div id=\"poll2\">\n";
	$rowPoll = mysql_fetch_assoc($resultPoll);
	
	$pID    = $rowPoll[PID];
	$pTitle = stripslashes($rowPoll[PollQ]); 
	
	// Get poll answers
	$sqlPoll = "SELECT * from ss_poll WHERE ParentID = '$pID' ORDER BY PID";
	$resultPoll = mysql_db_query($dbname,$sqlPoll);
	
	echo "<b>$pTitle</b><br>";
	echo "<div id=\"poll\">\n";
	echo "<table width=\"100%\">\n";
	while ($valuePoll = mysql_fetch_assoc($resultPoll)) {
		$pAID = $valuePoll[PID];
		$pA   = stripslashes($valuePoll[PollA]);
		
		echo "<tr><td valign=\"top\"><input type=\"radio\" onClick=\"logVote('".$pAID."');\" name=\"poll\" value=\"$pAID\"></td><td>$pA</td></tr>\n";
	}
	echo "</table>\n";
	echo "</div></div><img src=\"http://www.sonixshop.com/images/poll_footer.gif\" id=\"pollFooter\"></div>\n";
}	
?>
